<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<style>
#div_top {
	position: relative;
	z-index: 10000;
	height: 30px; /* 메뉴 사이즈 줄수 있음. */
	padding-top: 5px;
	border-radius: 10px 10px 10px 10px;
	box-shadow: 2px 2px 5px #aaaaaa;
}

#gnb {
	z-index: 10000;
	margin: 0;
	padding: 0;
	overflow: hidden
}

#gnb li {
	/* float: left; */
	display: inline-block;
	list-style: none;
	font: 13px 돋움 /*12px Tahoma, Arial  */
}

#gnb li a {
	display: block;
	font-weight: bold;
	background: #09C; /* 메인메뉴 색상  */
	padding: 5px 12px;
	text-decoration: none;
	/* border-right: 1px solid white; */
	width: 100px; /* 박스크기  */
	color: #EAFFED;
	white-space: nowrap
}

#gnb li a:hover {
	background: #676eb0 /* 마우스 오버시 상단 박스색상 #24313C(블랙)*/
}

#gnb li ul {
	width: 100px;
	margin: 0;
	padding: 0;
	position: absolute;
	display: none;
	/* border-top: 1px solid white */
}

#gnb li ul li {
	float: none;
	display: inline
}

#gnb li ul li a {
	width: 100px;
	background: #7fcce5; /* 연블루(#7fcce5) , 마우스오버 배경색상 #A9C251;(녹색)  */
	color: #24313C
}

#gnb li ul li a:hover {
	color: #ffffff;
	background: #676eb0 /*마우스 오버시 서브메뉴 박스색상 #8EA344(진녹) */
}

#top_logo {
	/* width:1200px;*/
	height: 110px;
	padding-top: 20px;
	text-align: center;
	font-color: #eeeeee;
	font-weight: bold;
	/* border: 1px solid #333333; */
}

#greet,#top_calendar,#top_info,#top_logout {
	display: inline-block;
}

#top_menu {
	z-index: 1000;
	width: 1600px;
	margin: auto;
	height: 20px;
	padding-top: 10px;
	font-size: 12px;
	font-weight: bold;
	color: #ffffff;
	background-color: #7fcce5;
}

.top_calendar {
	text-decoration: none;
	color: #ffffff;
}

.top_calendar:hover {
	text-decoration: none;
	color: #dddddd;
}

.top_info {
	text-decoration: none;
	color: #ffffff;
}

.top_info:hover {
	text-decoration: none;
	color: #dddddd;
}

.top_logout {
	text-decoration: none;
	color: #ffffff;
}

.top_logout:hover {
	text-decoration: none;
	color: #dddddd;
}

#top_backgra {
	width: 1200px;
	margin: auto;
	padding-right: 20px;
}
</style>
<script>
	function goBoard(bo_part, pageIndex){
		location.href = "${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./board/board_list.jsp&bo_part="+bo_part+"&nowPage="+1;
	}
</script>
<script src="${pageContext.request.contextPath }/homepage/main/js/jquery.min.js" type="text/javascript"></script>
<script src="${pageContext.request.contextPath }/homepage/main/js/gnbnav.js" type="text/javascript"></script>

</head>
<body>

	<%
	String id = (String)session.getAttribute("Mid");
	if (id == null || id.equals("")) {
	%>
	<script>
		location.href = "${pageContext.request.contextPath }/homepage/login/login.jsp"
	</script>
	<%} %>

	<%	
		String part = null;
		if (request.getParameter("part") != null) {
			part = request.getParameter("part");
			session.setAttribute("part", part);
		} else {
			if(session.getAttribute("part") == null){
				part = "공지사항";
				session.setAttribute("part", part);
			}else{
				part = (String)session.getAttribute("part");
			}
		}
		
		String sessionID = (String)session.getAttribute("SA_nm");
		
	%>
	<div id="top_menu">
		<div id="top_backgra" align="right">
			<div id="greet"><%=sessionID %> 님 방문해주셔서 고맙습니다..</div>
			<% if(session.getAttribute("Mid") != null && session.getAttribute("Mid").equals("1408M001")){ %>
			<div id="top_calendar">
				<a class='top_calendar'
					href="${pageContext.request.contextPath }/CalBBS.cal">회사일정관리</a>
			</div>
			/
			<%}%> 
			<div id="top_info">
				<a class='top_info'
					href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./salary/information_inquiry.jsp&SA_no=<%=(String)session.getAttribute("Mid")%>">정보조회</a>
			</div>
			/
			<div id="top_logout">
				<a class='top_logout' href="${pageContext.request.contextPath }/homepage/login/logout.jsp">로그아웃</a>
			</div>
		</div>
	</div>
	<div id="top_logo">
		<a href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./main/content.jsp"><img
			src="${pageContext.request.contextPath }/homepage/main/images/logoimg.jpg"></a>
	</div>
	<!-- <div id="top_logo">CLAMP</div> -->

	<nav>
	<div id="div_top"
		style="background-color: #09C; width: 1200px; margin: auto;"
		align="center">
		<ul id="gnb">
			<li><a href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./main/content.jsp">HOME</a>
			</li>
			<li><a href="#" onclick = "goBoard('공지사항')">공지사항</a>
			</li>
			<li><a href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./company/company_chart.jsp">조직도</a>
			</li>
			<li><a href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./product/product_list.jsp">상품소개</a>
			</li>
			<li><a
				href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./company/company_welfare.jsp">직원복지</a>
			</li>
			<li><a href="#" onclick = "goBoard('인사팀')">부서별게시판</a>
				<ul>
					<li><a href="#" onclick = "goBoard('인사팀')">인사팀</a></li>
					<li><a href="#" onclick = "goBoard('개발팀')">개발팀</a></li>
					<li><a href="#" onclick = "goBoard('총무팀')">총무팀</a></li>
					<li><a href="#" onclick = "goBoard('홍보팀')">홍보팀</a></li>
				</ul></li>
			<li><a href="#" onclick = "goBoard('건의사항')">건의사항</a>
			</li>
			<!-- <li><a href="index.jsp?inc_content=./salary/salary_list.jsp">사원관리</a> -->
			</li>
			<!-- 로그인이 된 상태에서만 볼수 있는 메뉴(H) -->
			<% if(session.getAttribute("Mid") != null && session.getAttribute("Mid").equals("1408M001")){ %>
				<li><a href="${pageContext.request.contextPath }/homepage/index.jsp?inc_content=./salary/salary_list.jsp">사원관리</a></li>	
			<%}%> 
		</ul>
	</div>
	</nav>

</body>
</html>